<script setup>
import { RouterLink, RouterView, useRouter } from "vue-router";
let router = useRouter();
let goLogin = () => {
  router.push("/login");
};
</script>

<template>
  <header>
    <h2 @click="goLogin">退出登录</h2>
  </header>

  <RouterView />
</template>

<style >
* {
  margin: 0;
  padding: 0;
}
.el-header {
  background-color: cadetblue;
}
h2 {
  position: absolute;
  top: 18px;
  right: 230px;

  font-weight: 500;
  color: #333;
  cursor: pointer;
  font-size: 16px;
}
h2:hover {
  color: darkolivegreen;
}
</style>
